package desktopapplication;

import java.io.ObjectInputStream;
import java.io.PrintWriter;
import java.net.Socket;
import static desktopapplication.GlobalVariables.*;
import java.io.ObjectOutputStream;
import java.util.Scanner;
import javax.swing.JOptionPane;

/**
 *
 * @author 王舒嶷
 * @version 0.0.2 beta
 */
public class DesktopApplication {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        // TODO code application logic here
        try {
            s = new Socket(URL, SBAP_PORT);
            instream = s.getInputStream();
            outstream = s.getOutputStream();
            out = new ObjectOutputStream(outstream);
            in = new ObjectInputStream(instream);
        } catch (Exception ex) {
            JOptionPane.showMessageDialog(null, "Unable to connect to server\nPlease check your internet connection", "Error", JOptionPane.INFORMATION_MESSAGE);
            ex.printStackTrace();
        }
        javax.swing.JFrame JF = new MainFrame();
        JF.setVisible(true);
    }
}
